<template>
	<view class="record-container">
		<u-cell-group>
			<u-cell size="large" isLink v-for="item in records" :key="item.id" :title="item.paperName"
				:value="item.status == 1?'去批改':'查看'"
				:label="`${item.subjectName} 对错：${item.questionCorrect}/${item.questionCount} 时间：${item.createTime}`" />
		</u-cell-group>
	</view>
</template>

<script>
	import http from '../../http';
	export default {
		data() {
			return {
				records: []
			}
		},
		methods: {
			getList() {
				http({
					url: '/api/student/exampaper/answer/pageList',
					method: 'POST',
					data: {
						pageIndex: 1,
						pageSize: 10
					}
				}).then(res => {
					console.log(res);
					this.records = res.response.list
				})
			}
		},
		onLoad() {
			this.getList()
		},
		onShow() {
			this.getList()
		}
	}
</script>

<style>

</style>